Integrand size = 16, antiderivative size = 418 \[ \int \frac {1}{x^3 \left (1-x^3+x^6\right )} \, dx=-\frac {1}{2 x^2}-\frac {\left (i-\sqrt {3}\right ) \arctan \left (\frac {1+\frac {2 x}{\sqrt [3]{\frac {1}{2} \left (1-i \sqrt {3}\right )}}}{\sqrt {3}}\right )}{3 \sqrt [3]{2} \left (1-i \sqrt {3}\right )^{2/3}}+\frac {\left (i+\sqrt {3}\right ) \arctan \left (\frac {1+\frac {2 x}{\sqrt [3]{\frac {1}{2} \left (1+i \sqrt {3}\right )}}}{\sqrt {3}}\right )}{3 \sqrt [3]{2} \left (1+i \sqrt {3}\right )^{2/3}}-\frac {\left (3-i \sqrt {3}\right ) \log \left (\sqrt [3]{1-i \sqrt {3}}-\sqrt [3]{2} x\right )}{9 \sqrt [3]{2} \left (1-i \sqrt {3}\right )^{2/3}}-\frac {\left (3+i \sqrt {3}\right ) \log \left (\sqrt [3]{1+i \sqrt {3}}-\sqrt [3]{2} x\right )}{9 \sqrt [3]{2} \left (1+i \sqrt {3}\right )^{2/3}}+\frac {\left (3-i \sqrt {3}\right ) \log \left (\left (1-i \sqrt {3}\right )^{2/3}+\sqrt [3]{2 \left (1-i \sqrt {3}\right )} x+2^{2/3} x^2\right )}{18 \sqrt [3]{2} \left (1-i \sqrt {3}\right )^{2/3}}+\frac {\left (3+i \sqrt {3}\right ) \log \left (\left (1+i \sqrt {3}\right )^{2/3}+\sqrt [3]{2 \left (1+i \sqrt {3}\right )} x+2^{2/3} x^2\right )}{18 \sqrt [3]{2} \left (1+i \sqrt {3}\right )^{2/3}} \]
[Out]
Time = 0.22 (sec) , antiderivative size = 418, normalized size of antiderivative = 1.00, number of steps used = 14, number of rules used = 8, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.500, Rules used = {1382, 1436, 206, 31, 648, 631, 210, 642} \[ \int \frac {1}{x^3 \left (1-x^3+x^6\right )} \, dx=-\frac {\left (-\sqrt {3}+i\right ) \arctan \left (\frac {1+\frac {2 x}{\sqrt [3]{\frac {1}{2} \left (1-i \sqrt {3}\right )}}}{\sqrt {3}}\right )}{3 \sqrt [3]{2} \left (1-i \sqrt {3}\right )^{2/3}}+\frac {\left (\sqrt {3}+i\right ) \arctan \left (\frac {1+\frac {2 x}{\sqrt [3]{\frac {1}{2} \left (1+i \sqrt {3}\right )}}}{\sqrt {3}}\right )}{3 \sqrt [3]{2} \left (1+i \sqrt {3}\right )^{2/3}}-\frac {1}{2 x^2}+\frac {\left (3-i \sqrt {3}\right ) \log \left (2^{2/3} x^2+\sqrt [3]{2 \left (1-i \sqrt {3}\right )} x+\left (1-i \sqrt {3}\right )^{2/3}\right )}{18 \sqrt [3]{2} \left (1-i \sqrt {3}\right )^{2/3}}+\frac {\left (3+i \sqrt {3}\right ) \log \left (2^{2/3} x^2+\sqrt [3]{2 \left (1+i \sqrt {3}\right )} x+\left (1+i \sqrt {3}\right )^{2/3}\right )}{18 \sqrt [3]{2} \left (1+i \sqrt {3}\right )^{2/3}}-\frac {\left (3-i \sqrt {3}\right ) \log \left (-\sqrt [3]{2} x+\sqrt [3]{1-i \sqrt {3}}\right )}{9 \sqrt [3]{2} \left (1-i \sqrt {3}\right )^{2/3}}-\frac {\left (3+i \sqrt {3}\right ) \log \left (-\sqrt [3]{2} x+\sqrt [3]{1+i \sqrt {3}}\right )}{9 \sqrt [3]{2} \left (1+i \sqrt {3}\right )^{2/3}} \]
[In]
[Out]
Rule 31
Rule 206
Rule 210
Rule 631
Rule 642
Rule 648
Rule 1382
Rule 1436
Rubi steps \begin{align*} \text {integral}& = -\frac {1}{2 x^2}+\frac {1}{2} \int \frac {2-2 x^3}{1-x^3+x^6} \, dx \\ & = -\frac {1}{2 x^2}+\frac {1}{6} \left (-3+i \sqrt {3}\right ) \int \frac {1}{-\frac {1}{2}+\frac {i \sqrt {3}}{2}+x^3} \, dx-\frac {1}{6} \left (3+i \sqrt {3}\right ) \int \frac {1}{-\frac {1}{2}-\frac {i \sqrt {3}}{2}+x^3} \, dx \\ & = -\frac {1}{2 x^2}-\frac {\left (3-i \sqrt {3}\right ) \int \frac {1}{-\sqrt [3]{\frac {1}{2} \left (1-i \sqrt {3}\right )}+x} \, dx}{9 \sqrt [3]{2} \left (1-i \sqrt {3}\right )^{2/3}}-\frac {\left (3-i \sqrt {3}\right ) \int \frac {-2^{2/3} \sqrt [3]{1-i \sqrt {3}}-x}{\left (\frac {1}{2} \left (1-i \sqrt {3}\right )\right )^{2/3}+\sqrt [3]{\frac {1}{2} \left (1-i \sqrt {3}\right )} x+x^2} \, dx}{9 \sqrt [3]{2} \left (1-i \sqrt {3}\right )^{2/3}}-\frac {\left (3+i \sqrt {3}\right ) \int \frac {1}{-\sqrt [3]{\frac {1}{2} \left (1+i \sqrt {3}\right )}+x} \, dx}{9 \sqrt [3]{2} \left (1+i \sqrt {3}\right )^{2/3}}-\frac {\left (3+i \sqrt {3}\right ) \int \frac {-2^{2/3} \sqrt [3]{1+i \sqrt {3}}-x}{\left (\frac {1}{2} \left (1+i \sqrt {3}\right )\right )^{2/3}+\sqrt [3]{\frac {1}{2} \left (1+i \sqrt {3}\right )} x+x^2} \, dx}{9 \sqrt [3]{2} \left (1+i \sqrt {3}\right )^{2/3}} \\ & = -\frac {1}{2 x^2}-\frac {\left (3-i \sqrt {3}\right ) \log \left (\sqrt [3]{1-i \sqrt {3}}-\sqrt [3]{2} x\right )}{9 \sqrt [3]{2} \left (1-i \sqrt {3}\right )^{2/3}}-\frac {\left (3+i \sqrt {3}\right ) \log \left (\sqrt [3]{1+i \sqrt {3}}-\sqrt [3]{2} x\right )}{9 \sqrt [3]{2} \left (1+i \sqrt {3}\right )^{2/3}}+\frac {\left (3-i \sqrt {3}\right ) \int \frac {\sqrt [3]{\frac {1}{2} \left (1-i \sqrt {3}\right )}+2 x}{\left (\frac {1}{2} \left (1-i \sqrt {3}\right )\right )^{2/3}+\sqrt [3]{\frac {1}{2} \left (1-i \sqrt {3}\right )} x+x^2} \, dx}{18 \sqrt [3]{2} \left (1-i \sqrt {3}\right )^{2/3}}+\frac {\left (3-i \sqrt {3}\right ) \int \frac {1}{\left (\frac {1}{2} \left (1-i \sqrt {3}\right )\right )^{2/3}+\sqrt [3]{\frac {1}{2} \left (1-i \sqrt {3}\right )} x+x^2} \, dx}{6\ 2^{2/3} \sqrt [3]{1-i \sqrt {3}}}+\frac {\left (3+i \sqrt {3}\right ) \int \frac {\sqrt [3]{\frac {1}{2} \left (1+i \sqrt {3}\right )}+2 x}{\left (\frac {1}{2} \left (1+i \sqrt {3}\right )\right )^{2/3}+\sqrt [3]{\frac {1}{2} \left (1+i \sqrt {3}\right )} x+x^2} \, dx}{18 \sqrt [3]{2} \left (1+i \sqrt {3}\right )^{2/3}}+\frac {\left (3+i \sqrt {3}\right ) \int \frac {1}{\left (\frac {1}{2} \left (1+i \sqrt {3}\right )\right )^{2/3}+\sqrt [3]{\frac {1}{2} \left (1+i \sqrt {3}\right )} x+x^2} \, dx}{6\ 2^{2/3} \sqrt [3]{1+i \sqrt {3}}} \\ & = -\frac {1}{2 x^2}-\frac {\left (3-i \sqrt {3}\right ) \log \left (\sqrt [3]{1-i \sqrt {3}}-\sqrt [3]{2} x\right )}{9 \sqrt [3]{2} \left (1-i \sqrt {3}\right )^{2/3}}-\frac {\left (3+i \sqrt {3}\right ) \log \left (\sqrt [3]{1+i \sqrt {3}}-\sqrt [3]{2} x\right )}{9 \sqrt [3]{2} \left (1+i \sqrt {3}\right )^{2/3}}+\frac {\left (3-i \sqrt {3}\right ) \log \left (\left (1-i \sqrt {3}\right )^{2/3}+\sqrt [3]{2 \left (1-i \sqrt {3}\right )} x+2^{2/3} x^2\right )}{18 \sqrt [3]{2} \left (1-i \sqrt {3}\right )^{2/3}}+\frac {\left (3+i \sqrt {3}\right ) \log \left (\left (1+i \sqrt {3}\right )^{2/3}+\sqrt [3]{2 \left (1+i \sqrt {3}\right )} x+2^{2/3} x^2\right )}{18 \sqrt [3]{2} \left (1+i \sqrt {3}\right )^{2/3}}-\frac {\left (3-i \sqrt {3}\right ) \text {Subst}\left (\int \frac {1}{-3-x^2} \, dx,x,1+\frac {2 x}{\sqrt [3]{\frac {1}{2} \left (1-i \sqrt {3}\right )}}\right )}{3 \sqrt [3]{2} \left (1-i \sqrt {3}\right )^{2/3}}-\frac {\left (3+i \sqrt {3}\right ) \text {Subst}\left (\int \frac {1}{-3-x^2} \, dx,x,1+\frac {2 x}{\sqrt [3]{\frac {1}{2} \left (1+i \sqrt {3}\right )}}\right )}{3 \sqrt [3]{2} \left (1+i \sqrt {3}\right )^{2/3}} \\ & = -\frac {1}{2 x^2}-\frac {\left (i-\sqrt {3}\right ) \tan ^{-1}\left (\frac {1+\frac {2 x}{\sqrt [3]{\frac {1}{2} \left (1-i \sqrt {3}\right )}}}{\sqrt {3}}\right )}{3 \sqrt [3]{2} \left (1-i \sqrt {3}\right )^{2/3}}+\frac {\left (i+\sqrt {3}\right ) \tan ^{-1}\left (\frac {1+\frac {2 x}{\sqrt [3]{\frac {1}{2} \left (1+i \sqrt {3}\right )}}}{\sqrt {3}}\right )}{3 \sqrt [3]{2} \left (1+i \sqrt {3}\right )^{2/3}}-\frac {\left (3-i \sqrt {3}\right ) \log \left (\sqrt [3]{1-i \sqrt {3}}-\sqrt [3]{2} x\right )}{9 \sqrt [3]{2} \left (1-i \sqrt {3}\right )^{2/3}}-\frac {\left (3+i \sqrt {3}\right ) \log \left (\sqrt [3]{1+i \sqrt {3}}-\sqrt [3]{2} x\right )}{9 \sqrt [3]{2} \left (1+i \sqrt {3}\right )^{2/3}}+\frac {\left (3-i \sqrt {3}\right ) \log \left (\left (1-i \sqrt {3}\right )^{2/3}+\sqrt [3]{2 \left (1-i \sqrt {3}\right )} x+2^{2/3} x^2\right )}{18 \sqrt [3]{2} \left (1-i \sqrt {3}\right )^{2/3}}+\frac {\left (3+i \sqrt {3}\right ) \log \left (\left (1+i \sqrt {3}\right )^{2/3}+\sqrt [3]{2 \left (1+i \sqrt {3}\right )} x+2^{2/3} x^2\right )}{18 \sqrt [3]{2} \left (1+i \sqrt {3}\right )^{2/3}} \\ \end{align*}
Result contains higher order function than in optimal. Order 9 vs. order 3 in optimal.
Time = 0.01 (sec) , antiderivative size = 65, normalized size of antiderivative = 0.16 \[ \int \frac {1}{x^3 \left (1-x^3+x^6\right )} \, dx=-\frac {1}{2 x^2}-\frac {1}{3} \text {RootSum}\left [1-\text {$\#$1}^3+\text {$\#$1}^6\&,\frac {-\log (x-\text {$\#$1})+\log (x-\text {$\#$1}) \text {$\#$1}^3}{-\text {$\#$1}^2+2 \text {$\#$1}^5}\&\right ] \]
[In]
[Out]
Result contains higher order function than in optimal. Order 9 vs. order 3.
Time = 0.05 (sec) , antiderivative size = 38, normalized size of antiderivative = 0.09
method | result | size |
risch | \(-\frac {1}{2 x^{2}}+\frac {\left (\munderset {\textit {\_R} =\operatorname {RootOf}\left (27 \textit {\_Z}^{6}+9 \textit {\_Z}^{3}+1\right )}{\sum }\textit {\_R} \ln \left (9 \textit {\_R}^{4}+3 \textit {\_R} +x \right )\right )}{3}\) | \(38\) |
default | \(\frac {\left (\munderset {\textit {\_R} =\operatorname {RootOf}\left (\textit {\_Z}^{6}-\textit {\_Z}^{3}+1\right )}{\sum }\frac {\left (-\textit {\_R}^{3}+1\right ) \ln \left (x -\textit {\_R} \right )}{2 \textit {\_R}^{5}-\textit {\_R}^{2}}\right )}{3}-\frac {1}{2 x^{2}}\) | \(50\) |
[In]
[Out]
none
Time = 0.25 (sec) , antiderivative size = 337, normalized size of antiderivative = 0.81 \[ \int \frac {1}{x^3 \left (1-x^3+x^6\right )} \, dx=\frac {2 \cdot 18^{\frac {2}{3}} x^{2} {\left (i \, \sqrt {3} - 3\right )}^{\frac {1}{3}} \log \left (18^{\frac {2}{3}} {\left (i \, \sqrt {3} + 3\right )} {\left (i \, \sqrt {3} - 3\right )}^{\frac {1}{3}} + 36 \, x\right ) + 2 \cdot 18^{\frac {2}{3}} x^{2} {\left (-i \, \sqrt {3} - 3\right )}^{\frac {1}{3}} \log \left (18^{\frac {2}{3}} {\left (-i \, \sqrt {3} + 3\right )} {\left (-i \, \sqrt {3} - 3\right )}^{\frac {1}{3}} + 36 \, x\right ) + 18^{\frac {2}{3}} {\left (\sqrt {-3} x^{2} - x^{2}\right )} {\left (i \, \sqrt {3} - 3\right )}^{\frac {1}{3}} \log \left (18^{\frac {2}{3}} {\left (\sqrt {3} {\left (i \, \sqrt {-3} - i\right )} + 3 \, \sqrt {-3} - 3\right )} {\left (i \, \sqrt {3} - 3\right )}^{\frac {1}{3}} + 72 \, x\right ) - 18^{\frac {2}{3}} {\left (\sqrt {-3} x^{2} + x^{2}\right )} {\left (i \, \sqrt {3} - 3\right )}^{\frac {1}{3}} \log \left (18^{\frac {2}{3}} {\left (\sqrt {3} {\left (-i \, \sqrt {-3} - i\right )} - 3 \, \sqrt {-3} - 3\right )} {\left (i \, \sqrt {3} - 3\right )}^{\frac {1}{3}} + 72 \, x\right ) - 18^{\frac {2}{3}} {\left (\sqrt {-3} x^{2} + x^{2}\right )} {\left (-i \, \sqrt {3} - 3\right )}^{\frac {1}{3}} \log \left (18^{\frac {2}{3}} {\left (\sqrt {3} {\left (i \, \sqrt {-3} + i\right )} - 3 \, \sqrt {-3} - 3\right )} {\left (-i \, \sqrt {3} - 3\right )}^{\frac {1}{3}} + 72 \, x\right ) + 18^{\frac {2}{3}} {\left (\sqrt {-3} x^{2} - x^{2}\right )} {\left (-i \, \sqrt {3} - 3\right )}^{\frac {1}{3}} \log \left (18^{\frac {2}{3}} {\left (\sqrt {3} {\left (-i \, \sqrt {-3} + i\right )} + 3 \, \sqrt {-3} - 3\right )} {\left (-i \, \sqrt {3} - 3\right )}^{\frac {1}{3}} + 72 \, x\right ) - 54}{108 \, x^{2}} \]
[In]
[Out]
Time = 0.09 (sec) , antiderivative size = 31, normalized size of antiderivative = 0.07 \[ \int \frac {1}{x^3 \left (1-x^3+x^6\right )} \, dx=\operatorname {RootSum} {\left (19683 t^{6} + 243 t^{3} + 1, \left ( t \mapsto t \log {\left (729 t^{4} + 9 t + x \right )} \right )\right )} - \frac {1}{2 x^{2}} \]
[In]
[Out]
\[ \int \frac {1}{x^3 \left (1-x^3+x^6\right )} \, dx=\int { \frac {1}{{\left (x^{6} - x^{3} + 1\right )} x^{3}} \,d x } \]
[In]
[Out]
Both result and optimal contain complex but leaf count of result is larger than twice the leaf count of optimal. 645 vs. \(2 (272) = 544\).
Time = 0.31 (sec) , antiderivative size = 645, normalized size of antiderivative = 1.54 \[ \int \frac {1}{x^3 \left (1-x^3+x^6\right )} \, dx=\text {Too large to display} \]
[In]
[Out]
Time = 8.81 (sec) , antiderivative size = 324, normalized size of antiderivative = 0.78 \[ \int \frac {1}{x^3 \left (1-x^3+x^6\right )} \, dx=\frac {\ln \left (x-\frac {\left (-\frac {27}{2}+\frac {\sqrt {3}\,9{}\mathrm {i}}{2}\right )\,{\left (-36-\sqrt {3}\,12{}\mathrm {i}\right )}^{1/3}}{54}\right )\,{\left (-36-\sqrt {3}\,12{}\mathrm {i}\right )}^{1/3}}{18}+\frac {\ln \left (x+\frac {\left (\frac {27}{2}+\frac {\sqrt {3}\,9{}\mathrm {i}}{2}\right )\,{\left (-36+\sqrt {3}\,12{}\mathrm {i}\right )}^{1/3}}{54}\right )\,{\left (-36+\sqrt {3}\,12{}\mathrm {i}\right )}^{1/3}}{18}-\frac {1}{2\,x^2}-\frac {2^{2/3}\,\ln \left (x-\frac {2^{2/3}\,{\left (-3-\sqrt {3}\,1{}\mathrm {i}\right )}^{1/3}\,\left (3^{1/3}+3^{5/6}\,1{}\mathrm {i}\right )\,\left (\frac {3\,\left (3+\sqrt {3}\,1{}\mathrm {i}\right )\,{\left (3^{1/3}+3^{5/6}\,1{}\mathrm {i}\right )}^3}{16}+27\right )}{108}\right )\,{\left (-3-\sqrt {3}\,1{}\mathrm {i}\right )}^{1/3}\,\left (3^{1/3}+3^{5/6}\,1{}\mathrm {i}\right )}{36}-\frac {2^{2/3}\,\ln \left (x+\frac {2^{2/3}\,{\left (-3+\sqrt {3}\,1{}\mathrm {i}\right )}^{1/3}\,\left (3^{1/3}-3^{5/6}\,1{}\mathrm {i}\right )\,\left (\frac {3\,\left (-3+\sqrt {3}\,1{}\mathrm {i}\right )\,{\left (3^{1/3}-3^{5/6}\,1{}\mathrm {i}\right )}^3}{16}-27\right )}{108}\right )\,{\left (-3+\sqrt {3}\,1{}\mathrm {i}\right )}^{1/3}\,\left (3^{1/3}-3^{5/6}\,1{}\mathrm {i}\right )}{36}-\frac {2^{2/3}\,\ln \left (x+\frac {2^{2/3}\,3^{5/6}\,{\left (-3-\sqrt {3}\,1{}\mathrm {i}\right )}^{1/3}\,1{}\mathrm {i}}{6}\right )\,{\left (-3-\sqrt {3}\,1{}\mathrm {i}\right )}^{1/3}\,\left (3^{1/3}-3^{5/6}\,1{}\mathrm {i}\right )}{36}-\frac {2^{2/3}\,\ln \left (x-\frac {2^{2/3}\,3^{5/6}\,{\left (-3+\sqrt {3}\,1{}\mathrm {i}\right )}^{1/3}\,1{}\mathrm {i}}{6}\right )\,{\left (-3+\sqrt {3}\,1{}\mathrm {i}\right )}^{1/3}\,\left (3^{1/3}+3^{5/6}\,1{}\mathrm {i}\right )}{36} \]
[In]
[Out]